doctype
html.login-bg
    head
        include ../include/meta
        title #{title}
        include ../include/bootstrap
        include ../include/globalStyle

        <!-- libraries -->
        link(href="/vendor/css/lib/font-awesome.css",rel="stylesheet")
        <!-- this page specific styles -->
        link(href="/vendor/css/compiled/form-showcase.css",rel="stylesheet",media="screen")
        <!-- open sans font -->
        link(href="http://fonts.googleapis.com/css?family=Open+Sans:300italic,400italic,700italic,800italic,400,300,600,700,800",rel="stylesheet",media="screen")


    body
        include ../include/navbar
        include ../include/sidebar
        .content
            .container-fluid
                .users-list#pad-wrapper
                    .row-fluid.header
                        h3 #{title}
                    .row-fluid
                        .span4
                        .span4
                            form(method="POST" action="/admin/user/update")
                                input(type="hidden" name="user[_id]" value=user0._id)
                                div.field-box
                                    label(for="signUpName") 用户名：
                                    input.span12(id="signUpName" name="user[name]" type="text" required="required" value=user0.name)
                                div.field-box
                                    label(for="signUpNickName") 昵称：
                                    input.span12(id="signUpNickName" name="user[nickName]" type="text" required="required" value=user0.nickName)
                                div.field-box
                                    label(for="signUpPhone") 手机：
                                    input.span12(id="signUpPhone" name="user[phone]" type="text" required="required" value=user0.phone)
                                div.field-box
                                    label(for="signUpEmail") 邮箱：
                                    input.span12(id="signUpEmail" name="user[email]" type="text" required="required" value=user0.email)
                                div.field-box
                                    label.col-sm-2.col-sm-offset-3.control-label 性别：
                                    .span12
                                        if user0.sex == "male"
                                            label.span4.radio-inline(for="signUpSexMale")
                                                input(id="signUpSexMale" name="user[sex]" type="radio" value="male" checked="checked")
                                                | 男
                                            label.span4.radio-inline(for="signUpSexFemale")
                                                input(id="signUpSexFemale" name="user[sex]" type="radio" value="female")
                                                | 女
                                        else
                                            label.span4.radio-inline(for="signUpSexMale")
                                                input(id="signUpSexMale" name="user[sex]" type="radio" value="male")
                                                | 男
                                            label.span4.radio-inline(for="signUpSexFemale")
                                                input(id="signUpSexFemale" name="user[sex]" type="radio" value="female" checked="checked")
                                                | 女
                                div.field-box
                                    label(for="signUpLevel") 等级：
                                    input.span12(id="signUpLevel" name="user[level]" type="number" required="required" value=user0.level)
                                div.field-box
                                    label(for="signUpLevel") 渠道：
                                    mixin option(value)
                                        if user0.way && String(user0.way) == value._id
                                            option(value=value._id selected)=value.name
                                        else
                                            option(value=value._id)=value.name
                                    select.select2.span12(id="signUpWay" name="user[way]")
                                        option(value='')='请选择'
                                        each val in ways
                                            +option(val)
                                div.field-box(style="margin-top:20px;")
                                    div.text-center
                                        input.pull-left.btn-flat.success(id="submit" type="submit" value="提交")
                                        input.pull-right.btn-flat.gray(id="reset" type="reset" value="重置")


    script(src="/vendor/js/jquery-3.2.1.min.js")
    script(src="/vendor/js/bootstrap.min.js")
    script(src="/vendor/js/theme.js")
